"""meiduo_mall URL Configuration

The `urlpatterns` list routes URLs to views. For more information please see:
    https://docs.djangoproject.com/en/1.11/topics/http/urls/
Examples:
Function views
    1. Add an import:  from my_app import views
    2. Add a URL to urlpatterns:  url(r'^$', views.home, name='home')
Class-based views
    1. Add an import:  from other_app.views import Home
    2. Add a URL to urlpatterns:  url(r'^$', Home.as_view(), name='home')
Including another URLconf
    1. Import the include() function: from django.conf.urls import url, include
    2. Add a URL to urlpatterns:  url(r'^blog/', include('blog.urls'))
"""
from django.conf.urls import url, include
from django.contrib import admin
from rest_framework_jwt.views import obtain_jwt_token

urlpatterns = [
    url(r'^admin/', admin.site.urls),
    # 用户子应用
    url(r'^', include("apps.users.urls", namespace="users")),
    # 主页子应用
    url(r'^', include("apps.contents.urls", namespace="contents")),
    # 生成图形/短信验证码子应用
    url(r'^', include("apps.verifications.urls")),
    # 第三方QQ登录子应用
    url(r'^', include('apps.oauth.urls',namespace="oauth")),
    # 城市数据
    url(r'^', include('apps.areas.urls',namespace="areas")),
    # 商品数据
    url(r'^', include('apps.goods.urls',namespace="goods")),
    # 购物车数据
    url(r'^', include('apps.carts.urls',namespace="carts")),
    # 订单
    url(r'^', include('apps.orders.urls',namespace="orders")),
    # 支付
    url(r'^', include('apps.payment.urls',namespace="payment")),
    # 找回密码
    url(r'^', include('apps.findpasswords.urls',namespace="findpasswords")),
    # 全文检索
    url(r'^search/', include('haystack.urls')),
    # 图书逻辑
    url(r'^', include('apps.books.urls')),
    # 后台
    url(r'^meiduo_admin/', include('apps.meiduo_admin.urls')),



]
